home *** CD-ROM | disk | FTP | other *** search
- on enterFrame
- set xCenter to ((the left of sprite 3 + the right of sprite 3) / 2) + 1
- set yCenter to ((the top of sprite 3 + the bottom of sprite 3) / 2) + 1
- set radius to (the width of sprite 3 / 2) - 2
- set the trails of sprite 4 to 1
- repeat with n = 0 to 360
- if the mouseDown then
- exit repeat
- end if
- set dy to float(radius) * float(sin((360 - n) * PI / 180.0))
- set dx to float(radius) * float(cos(n * PI / 180.0))
- drawLine(4, yCenter, xCenter, yCenter + dy, xCenter + dx)
- if (n = 30) or (n = 60) or (n = 90) or (n = 180) or (n = 45) or (n = 270) or (n = 135) or (n = 360) then
- if n = 180 then
- put "pi Radians" into field "Degree"
- end if
- if n = 30 then
- put "pi/6 Radians" into field "Degree"
- end if
- if n = 30 then
- put "pi/6 Radians" into field "Degree"
- end if
- if n = 60 then
- put "pi/3 Radians" into field "Degree"
- end if
- if n = 45 then
- put "pi/4 Radians" into field "Degree"
- end if
- if n = 90 then
- put "pi/2 Radians" into field "Degree"
- end if
- if n = 135 then
- put "3/4•pi Radians" into field "Degree"
- end if
- if n = 270 then
- put "3/2•pi Radians" into field "Degree"
- end if
- if n = 360 then
- put "2•pi Radians" into field "Degree"
- end if
- updateStage()
- startTimer()
- repeat while the timer < (3 * 60)
- if the mouseDown then
- exit repeat
- end if
- end repeat
- next repeat
- end if
- set the floatPrecision to 2
- put n * PI / 180.0 & " Radians" into field "Degree"
- updateStage()
- end repeat
- set the trails of sprite 4 to 0
- end
-